<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:f="http://java.sun.com/jsf/core"      
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:c="http://java.sun.com/jsp/jstl/core">
    
    <body >	
    	<ui:composition template="/user/template.xhtml">
    	<c:if test="#{!searchTeamBean.afterSearch}">
    		<h1>Nejříve vyberte sezónu a soutěž v levém panelu.</h1>
    	</c:if>
    	<c:if test="#{searchTeamBean.afterSearch}">	
    		<h1>#{searchTeamBean.competionGUI} - #{searchTeamBean.seasonGUI}</h1>
	        <h:outputText value="Kolo: #{searchTeamBean.actualRound}" />
	        
			
			  <br/>              
              <c:forEach varStatus="status" var="matchDate" items="#{searchTeamBean.matchDates}" >
              		<table style="margin-top:0px;">
              			<tr id="#{matchDate}" >
              			<td style="font-weight: bolder;font-size: 13px;" >#{matchDate}</td>
              			</tr>
              		</table>
<!--               		<div id="#{matchDate}" >#{matchDate}</div><br/> -->
			        <table id="matchTable" class="matchtb" style="margin-top:0px;">
			             <c:forEach varStatus="status" var="match" items="#{searchTeamBean.frontMatch}" >
						         <c:if test="#{matchDate eq match.zacatek}" >          
						                   <tr>   
						                      <td style="width: 0%;"/>
						                      <td style="width: 3%;display:none;" >#{match.kolo}</td>
						                      <td style="width: 3%;display:none;white-space: nowrap;" >.kolo</td>
						                      <td style="width: 3%;display:none;" >#{match.zacatek}</td>
						                      <td style="width: 10%;" >#{match.cas}</td>
						                      <td><!-- <img src="../img/tym/slaviahk.gif" /> --></td>
						                      <td style="width: 35%;" >#{match.domaci}</td>
						                      <td style="width: 5%;" >-</td>
						                      <td><!-- <img src="../img/tym/slaviahk.gif" /> --></td>
					                    	  <td style="width: 35%;" >#{match.hoste} <b style="font-size:10px; font-weight:normal;"> #{match.poznamka}</b></td>
				                   		      <td style="width: 5%;">#{match.domaciSkore}:#{match.hosteSkore}</td>
				                   		      <td style="width: 10%;"><a href="detailzapasu.xhtml?id=#{match.seasonCompetionId}_#{match.idmatch}" style="color:black;">detail</a></td>
				                		 </tr>
				               </c:if> 		 	             		 	
			             </c:forEach>
			        </table>                	
              </c:forEach>
              <br />  		         
             <c:if test="#{searchTeamBean.seasonId eq '2'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=2_1">vyberte</option>
					    <option value="rozpis.xhtml?id=2_1">1</option>
					    <option value="rozpis.xhtml?id=2_2">2</option>
					    <option value="rozpis.xhtml?id=2_3">3</option>
					    <option value="rozpis.xhtml?id=2_4">4</option>
					    <option value="rozpis.xhtml?id=2_5">5</option>
					    <option value="rozpis.xhtml?id=2_6">6</option>
					    <option value="rozpis.xhtml?id=2_7">7</option>
					    <option value="rozpis.xhtml?id=2_8">8</option>
					    <option value="rozpis.xhtml?id=2_9">9</option>
					    <option value="rozpis.xhtml?id=2_10">10</option>
					    <option value="rozpis.xhtml?id=2_11">11</option>
					    <option value="rozpis.xhtml?id=2_12">12</option>
					    <option value="rozpis.xhtml?id=2_13">13</option>
					    <option value="rozpis.xhtml?id=2_14">14</option>
					    <option value="rozpis.xhtml?id=2_15">15</option>
					</select>
			</c:if>
			<c:if test="#{searchTeamBean.seasonId eq '3'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=3_1">vyberte</option>
					    <option value="rozpis.xhtml?id=3_1">1</option>
					    <option value="rozpis.xhtml?id=3_2">2</option>
					    <option value="rozpis.xhtml?id=3_3">3</option>
					    <option value="rozpis.xhtml?id=3_4">4</option>
					    <option value="rozpis.xhtml?id=3_5">5</option>
					    <option value="rozpis.xhtml?id=3_6">6</option>
					    <option value="rozpis.xhtml?id=3_7">7</option>
					    <option value="rozpis.xhtml?id=3_8">8</option>
					    <option value="rozpis.xhtml?id=3_9">9</option>
					    <option value="rozpis.xhtml?id=3_10">10</option>
					    <option value="rozpis.xhtml?id=3_11">11</option>
					    <option value="rozpis.xhtml?id=3_12">12</option>
					    <option value="rozpis.xhtml?id=3_13">13</option>
					</select>
			</c:if>
			<c:if test="#{searchTeamBean.seasonId eq '4'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=4_1">vyberte</option>
					    <option value="rozpis.xhtml?id=4_1">1</option>
					    <option value="rozpis.xhtml?id=4_2">2</option>
					    <option value="rozpis.xhtml?id=4_3">3</option>
					    <option value="rozpis.xhtml?id=4_4">4</option>
					    <option value="rozpis.xhtml?id=4_5">5</option>
					    <option value="rozpis.xhtml?id=4_6">6</option>
					    <option value="rozpis.xhtml?id=4_7">7</option>
					    <option value="rozpis.xhtml?id=4_8">8</option>
					    <option value="rozpis.xhtml?id=4_9">9</option>
					    <option value="rozpis.xhtml?id=4_10">10</option>
					    <option value="rozpis.xhtml?id=4_11">11</option>
					    <option value="rozpis.xhtml?id=4_12">12</option>
					    <option value="rozpis.xhtml?id=4_13">13</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '5'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=5_1">vyberte</option>
					    <option value="rozpis.xhtml?id=5_1">1</option>
					    <option value="rozpis.xhtml?id=5_2">2</option>
					    <option value="rozpis.xhtml?id=5_3">3</option>
					    <option value="rozpis.xhtml?id=5_4">4</option>
					    <option value="rozpis.xhtml?id=5_5">5</option>
					    <option value="rozpis.xhtml?id=5_6">6</option>
					    <option value="rozpis.xhtml?id=5_7">7</option>
					    <option value="rozpis.xhtml?id=5_8">8</option>
					    <option value="rozpis.xhtml?id=5_9">9</option>
					    <option value="rozpis.xhtml?id=5_10">10</option>
					    <option value="rozpis.xhtml?id=5_11">11</option>
					    <option value="rozpis.xhtml?id=5_12">12</option>
					    <option value="rozpis.xhtml?id=5_13">13</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '6'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=6_1">vyberte</option>
					    <option value="rozpis.xhtml?id=6_1">1</option>
					    <option value="rozpis.xhtml?id=6_2">2</option>
					    <option value="rozpis.xhtml?id=6_3">3</option>
					    <option value="rozpis.xhtml?id=6_4">4</option>
					    <option value="rozpis.xhtml?id=6_5">5</option>
					    <option value="rozpis.xhtml?id=6_6">6</option>
					    <option value="rozpis.xhtml?id=6_7">7</option>
					    <option value="rozpis.xhtml?id=6_8">8</option>
					    <option value="rozpis.xhtml?id=6_9">9</option>
					    <option value="rozpis.xhtml?id=6_10">10</option>
					    <option value="rozpis.xhtml?id=6_11">11</option>
					    <option value="rozpis.xhtml?id=6_12">12</option>
					    <option value="rozpis.xhtml?id=6_13">13</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '7'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=7_1">vyberte</option>
					    <option value="rozpis.xhtml?id=7_1">1</option>
					    <option value="rozpis.xhtml?id=7_2">2</option>
					    <option value="rozpis.xhtml?id=7_3">3</option>
					    <option value="rozpis.xhtml?id=7_4">4</option>
					    <option value="rozpis.xhtml?id=7_5">5</option>
					    <option value="rozpis.xhtml?id=7_6">6</option>
					    <option value="rozpis.xhtml?id=7_7">7</option>
					    <option value="rozpis.xhtml?id=7_8">8</option>
					    <option value="rozpis.xhtml?id=7_9">9</option>
					    <option value="rozpis.xhtml?id=7_10">10</option>
					    <option value="rozpis.xhtml?id=7_11">11</option>
					    <option value="rozpis.xhtml?id=7_12">12</option>
					    <option value="rozpis.xhtml?id=7_13">13</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '8'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=8_1">vyberte</option>
					    <option value="rozpis.xhtml?id=8_1">1</option>
					    <option value="rozpis.xhtml?id=8_2">2</option>
					    <option value="rozpis.xhtml?id=8_3">3</option>
					    <option value="rozpis.xhtml?id=8_4">4</option>
					    <option value="rozpis.xhtml?id=8_5">5</option>
					    <option value="rozpis.xhtml?id=8_6">6</option>
					    <option value="rozpis.xhtml?id=8_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '9'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=9_1">vyberte</option>
					    <option value="rozpis.xhtml?id=9_1">1</option>
					    <option value="rozpis.xhtml?id=9_2">2</option>
					    <option value="rozpis.xhtml?id=9_3">3</option>
					    <option value="rozpis.xhtml?id=9_4">4</option>
					    <option value="rozpis.xhtml?id=9_5">5</option>
					    <option value="rozpis.xhtml?id=9_6">6</option>
					    <option value="rozpis.xhtml?id=9_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '10'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=10_1">vyberte</option>
					    <option value="rozpis.xhtml?id=10_1">1</option>
					    <option value="rozpis.xhtml?id=10_2">2</option>
					    <option value="rozpis.xhtml?id=10_3">3</option>
					    <option value="rozpis.xhtml?id=10_4">4</option>
					    <option value="rozpis.xhtml?id=10_5">5</option>
					    <option value="rozpis.xhtml?id=10_6">6</option>
					    <option value="rozpis.xhtml?id=10_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '11'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=11_1">vyberte</option>
					    <option value="rozpis.xhtml?id=11_1">1</option>
					    <option value="rozpis.xhtml?id=11_2">2</option>
					    <option value="rozpis.xhtml?id=11_3">3</option>
					    <option value="rozpis.xhtml?id=11_4">4</option>
					    <option value="rozpis.xhtml?id=11_5">5</option>
					    <option value="rozpis.xhtml?id=11_6">6</option>
					    <option value="rozpis.xhtml?id=11_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '12'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=12_1">vyberte</option>
					    <option value="rozpis.xhtml?id=12_1">1</option>
					    <option value="rozpis.xhtml?id=12_2">2</option>
					    <option value="rozpis.xhtml?id=12_3">3</option>
					    <option value="rozpis.xhtml?id=12_4">4</option>
					    <option value="rozpis.xhtml?id=12_5">5</option>
					    <option value="rozpis.xhtml?id=12_6">6</option>
					    <option value="rozpis.xhtml?id=12_7">7</option>
					    <option value="rozpis.xhtml?id=12_8">8</option>
					    <option value="rozpis.xhtml?id=12_9">9</option>
					    <option value="rozpis.xhtml?id=12_10">10</option>
					    <option value="rozpis.xhtml?id=12_11">11</option>
					    <option value="rozpis.xhtml?id=12_12">12</option>
					    <option value="rozpis.xhtml?id=12_13">13</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '13'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=13_1">vyberte</option>
					    <option value="rozpis.xhtml?id=13_1">1</option>
					    <option value="rozpis.xhtml?id=13_2">2</option>
					    <option value="rozpis.xhtml?id=13_3">3</option>
					    <option value="rozpis.xhtml?id=13_4">4</option>
					    <option value="rozpis.xhtml?id=13_5">5</option>
					    <option value="rozpis.xhtml?id=13_6">6</option>
					    <option value="rozpis.xhtml?id=13_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '14'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=14_1">vyberte</option>
					    <option value="rozpis.xhtml?id=14_1">1</option>
					    <option value="rozpis.xhtml?id=14_2">2</option>
					    <option value="rozpis.xhtml?id=14_3">3</option>
					    <option value="rozpis.xhtml?id=14_4">4</option>
					    <option value="rozpis.xhtml?id=14_5">5</option>
					    <option value="rozpis.xhtml?id=14_6">6</option>
					    <option value="rozpis.xhtml?id=14_7">7</option>
					</select>
			</c:if>
			
			<c:if test="#{searchTeamBean.seasonId eq '15'}">
		            <h:outputText value=" další kola: " />
		           	<select onchange="window.open(this.options[this.selectedIndex].value,'_top')">
					    <option value="rozpis.xhtml?id=15_1">vyberte</option>
					    <option value="rozpis.xhtml?id=15_1">1</option>
					    <option value="rozpis.xhtml?id=15_2">2</option>
					    <option value="rozpis.xhtml?id=15_3">3</option>
					    <option value="rozpis.xhtml?id=15_4">4</option>
					    <option value="rozpis.xhtml?id=15_5">5</option>
					    <option value="rozpis.xhtml?id=15_6">6</option>
					    <option value="rozpis.xhtml?id=15_7">7</option>
					    <option value="rozpis.xhtml?id=15_8">8</option>
					    <option value="rozpis.xhtml?id=15_9">9</option>
					    <option value="rozpis.xhtml?id=15_10">10</option>
					    <option value="rozpis.xhtml?id=15_11">11</option>
					    <option value="rozpis.xhtml?id=15_12">12</option>
					    <option value="rozpis.xhtml?id=15_13">13</option>
					</select>
			</c:if>
              <table class="center">
                  <tr>
                      <th>Pořadí</th>
                      <th colspan="2">Tým</th>
                      <th>Zápasy</th>
                      <th>V</th>
                      <th>R</th>
                      <th>P</th>
                      <th>Skóre</th>
                      <th>Body</th>
                  </tr>
                  
                  <c:forEach var="team"  items="#{searchTeamBean.frontTable}" varStatus="status" >
	                  	<tr class="vedouci">
	                      <td>#{team.poradi}</td>
	                      <td></td>
	                      <td class="doleva"><span style="color:black;">#{team.tym}</span></td>
	                      <td>#{team.zapasy}</td>
	                      <td>#{team.vyhry}</td>
	                      <td>#{team.remizy}</td>
	                      <td>#{team.prohry}</td>
	                      <td>#{team.vstreleneGoly}:#{team.obdrzeneGoly}</td>
	                      <td>#{team.body}</td>
	                  	</tr>
                  </c:forEach>
              </table> 
              
              
               
        </c:if>  
    	</ui:composition>
	</body>
</html>